import Vue from 'vue'
import Vuex from 'vuex'
import getters from './getters'
import app from './modules/app'
import settings from './modules/settings'
import user from './modules/user'

Vue.use(Vuex) // 给Vue原型上添加$store属性

const store = new Vuex.Store({ // new一个唯一的store仓库对象
  modules: {
    // 模块名: 模块对象
    // app: app
    app,
    settings,
    user
  },
  getters
})

export default store
